package com.lagou.controller;

import com.lagou.entity.Position;
import com.lagou.service.PositionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;
import java.util.Map;

@Controller
@RequestMapping("/position")
public class PositionController {

    @Autowired
    private PositionService positionService;
    @RequestMapping("/queryPosition")
    public List<Map<String,Object>> list(@RequestParam(value = "position") String name) throws Exception {
        return positionService.queryPositions(name);
    }



}
